package com.qianzhou.mapper;

import com.qianzhou.pojo.Order;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface OrderMapper {
    /**
     * 多对一和一对一的写法
     * @return
     */
    public List<Order> findAllWithUser();
    @Select("SELECT * FROM orders WHERE uid = #{uid}")
    public List<Order> findByUid(Integer uid);
}
